/*
	定制并显示命令提示符
*/

var readline = require('readline');
var r1 = readline.createInterface({
	input: process.stdin,
	output: process.stdout
});

r1.setPrompt("请输入：", 8);
r1.prompt();

r1.on('line', function(line) {
	if(line == 'exit' || line == 'quit' || line == 'q')
		r1.close();
	else
		console.log("您输入了：" + line);
	r1.prompt();
});

r1.on('close', function(){
	console.log("\r\n行数据读取操作被终止");
})

